package gin_handler

import (
	current_scope "app/app_src/framework/security/current/scope"

	"github.com/gin-gonic/gin"
)

func CurrentScopeHandler(c *gin.Context) {
	// 在请求开始前和结束后清理 current_scope 脏数据
	current_scope.SetAll(nil)
	defer current_scope.RemoveAll()

	c.Next()
}
